<?php
namespace app\admin\controller\sysSet;
use \app\sys\model\Hint as HintModel;
use \think\Request;

class Hint extends \app\common\Common
{
    public function list()
    {
        $list = HintModel::list();
        return successJson("success",$list);
    }

    public function up(Request $request)
    {
        $id = $request->param("id");
        $text = $request->param("text");
        $is_time = $request->param("is_time");
        HintModel::up($id,$text,$is_time);
        return successJson("success");
    }

    public function del(Request $request)
    {
        $id = $request->param("id");
        return failedJson("暂不支持删除~");
        HintModel::del($id);
        return successJson("success");
    }

    public function stat(Request $request)
    {
        $id = $request->param("id");
        $status = $request->param("status");
        HintModel::stat($id,$status);
        return successJson("success");
    }
}